﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using shop.entity;
using shop.service;

namespace shop.web.common
{
    public partial class Common : System.Web.UI.MasterPage
    {
        protected User user = new User();
        protected int logined =0;
        protected string userName;
        public string baseUrl;
        private CatagoryService catagoryService = new CatagoryService();

        protected List<Catagory> catagoryList;
        protected void Page_Load(object sender, EventArgs e)
        {
            baseUrl = Request.PhysicalApplicationPath;
            catagoryList = catagoryService.ListCatagory();
            if (Session["user"]!=null) {
                logined = 1;
                user = (User)Session["user"];
                userName = user.Name;
            }
        }
    }
}